function ret=calculate_joinnode(reliability,path)
len=length(path);
ret=1;
join_node=[];
if len==1
    for i=1:length(path{1})
        ret=ret*reliability(path{1}(i));
    end
else
    for i=1:len
        join_node=union(path{i},join_node);
    end
    for j=1:length(join_node)
        ret=ret*reliability(join_node(j));
    end
end